
import Vue from 'vue'

import Cookies from 'js-cookie'

import 'normalize.css/normalize.css' // a modern alternative to CSS resets

import Element from 'element-ui'
import './styles/element-variables.scss'

import '@/styles/index.scss' // global css

import App from './App'
import store from './store'
import router from './router'

import './icons' // icon
import './permission' // permission control

import echarts from 'echarts'
Vue.prototype.$echarts = echarts

import VueSocketIO from 'vue-socket.io'
import SocketIO from 'socket.io-client'

import qs from 'qs'
Vue.prototype.$qs = qs

Vue.use(Element, {
  size: Cookies.get('size') || 'medium' // set element-ui default size
})

Vue.use(new VueSocketIO({
  debug: true,
  connection: SocketIO('ws://localhost:8000')
}))

Vue.config.productionTip = false
// Vue.prototype.$BASE_URL = 'http://39.108.166.29'

new Vue({
  el: '#app',
  router,
  store,
  render: h => h(App)
})
